#pragma once

#include "../attribute/attribute.h"

#define NO_NAME		"unknown"	
#define MAX_LEVEL	0xff

class ObjCommon
{
public:
	ObjCommon(char* n = NO_NAME);
	virtual ~ObjCommon();

protected:
	char name[256];
	unsigned int level;

	HealthVals health;
	FightVals fight;
	DefenceVals defence;

protected:
	virtual void update() = 0;
	virtual void initVals() = 0;
	virtual void initName(char* n);

public:
	const char* getName(){return name;}
	
	virtual void levelUp();
	virtual void levelUp(unsigned int grow);
	virtual void levelUpto(unsigned int l);
	virtual void showValsInfo();
};